home *** CD-ROM | disk | FTP | other *** search
/ Apple Macintosh CD: Power Macintosh 5200/75 / Apple Macintosh CD - Power Macintosh 5200_75.7z / Apple Macintosh CD - Power Macintosh 5200_75.bin / Extras / PowerTalk Extras / PowerTalk Mail Gateways / STF PowerFax™ PE Gateway / PowerFax™ PE Installer / STFApplications.sit / ARA Scripts / GVC 14400 (LnMgr) < prev    next >
Text File  |  1994-07-11  |  3KB  |  203 lines

  1. ! "GVC 14400 - 7/30/91"
  2. ! This script has been verified to work with Line Manager
  3. !
  4. @ORIGINATE
  5. @ANSWER
  6. !
  7. @LABEL 1
  8. serreset 19200, 0, 8, 1
  9. !
  10. ! first recall the factory configuration
  11. !
  12. matchclr
  13. matchstr 1 4 "OK\13\10"
  14. write "AT&F\13"
  15. matchread 30
  16. jump 59
  17. !
  18. ! Next, Set up the configuration:
  19. !
  20. @LABEL 4
  21. pause 5
  22. matchstr 1 6 "OK\13\10"
  23. ! \N1 : Direct mode (default \N0)
  24. ! \J1 : Serial rate matches modem rate (default \J0)
  25. ! &D3 : Reset following DTR Transition (default &D2)
  26. ! S0=0: Turn off auto-answer
  27. ! E0: Turn off echo
  28. write "AT\\N1\\J1&D3S0=0E0\13"
  29. matchread 30
  30. jump 59
  31. !
  32. ! If speaker on flag is true, jump to label 8. Else turn off speaker.
  33. @LABEL 6
  34. ifstr 2 8 "1"
  35. matchstr 1 8 "OK\13\10"
  36. write "ATM0\13"
  37. matchread 30
  38. jump 59
  39. !
  40. ! The modem is ready so enable answering, or originate a call
  41. !
  42. @LABEL 8
  43. pause 5
  44. ifANSWER 30
  45. note "Dialing ^1" 3
  46. write "ATDT^1\13"
  47. !
  48. @LABEL 9
  49. matchstr 1 11 "CONNECT 1200\13\10"
  50. matchstr 2 12 "CONNECT 2400\13\10"
  51. matchstr 3 13 "CONNECT 4800\13\10"
  52. matchstr 4 14 "CONNECT 7200\13\10"
  53. matchstr 5 15 "CONNECT 9600\13\10"
  54. matchstr 6 16 "CONNECT 12000\13\10"
  55. matchstr 7 17 "CONNECT 14400\13\10"
  56. matchstr 8 50 "NO CARRIER\13\10"
  57. matchstr 9 50 "ERROR\13\10"
  58. matchstr 10 52 "NO DIALTONE\13\10"
  59. matchstr 11 53 "BUSY\13\10"
  60. matchstr 12 54 "NO ANSWER\13\10"
  61. matchread 700
  62. jump 59
  63. !
  64. @LABEL 11
  65. note "Communicating at 1200 bps." 2
  66. setspeed 1200
  67. jump 20
  68. !
  69. @LABEL 12
  70. note "Communicating at 2400 bps." 2
  71. setspeed 2400
  72. jump 20
  73. !
  74. @LABEL 13
  75. note "Communicating at 4800 bps." 2
  76. setspeed 4800
  77. jump 20
  78. !
  79. @LABEL 14
  80. note "Communicating at 7200 bps." 2
  81. setspeed 7200
  82. jump 20
  83. !
  84. @LABEL 15
  85. note "Communicating at 9600 bps." 2
  86. setspeed 9600
  87. jump 20
  88. !
  89. @LABEL 16
  90. note "Communicating at 12000 bps." 2
  91. setspeed 12000
  92. jump 20
  93. !
  94. @LABEL 17
  95. note "Communicating at 14400 bps." 2
  96. setspeed 14400
  97. jump 20
  98. !
  99. ! Finished. Return with good results
  100. @LABEL 20  
  101. exit 0
  102. !
  103. ! @ANSWER
  104. ! Set up the modem to answer
  105. @LABEL 30
  106. write "ATS0=1\13"
  107. matchstr 1 31 "OK\13\10"
  108. matchread 30
  109. jump 59
  110. !
  111. @LABEL 31
  112. matchstr 1  32 "RING\13\10"
  113. matchstr 2  11 "CONNECT 1200\13\10"
  114. matchstr 3  12 "CONNECT 2400\13\10"
  115. matchstr 4  13 "CONNECT 4800\13\10"
  116. matchstr 5     14 "CONNECT 7200\13\10"
  117. matchstr 6  15 "CONNECT 9600\13\10"
  118. matchstr 7     16 "CONNECT 12000\13\10"
  119. matchstr 8  17 "CONNECT 14400\13\10"
  120. matchstr 9  50 "NO CARRIER\13\10"
  121. matchstr 10    50 "ERROR\13\10"
  122. matchstr 11    52 "NO DIALTONE\13\10"
  123. matchstr 12    53 "BUSY\13\10"
  124. matchstr 13 54 "NO ANSWER\13\10"
  125. matchread 700
  126. jump 31
  127. !
  128. @LABEL 32
  129. userhook 1
  130. note "Answering phone…" 2
  131. jump 31
  132. !
  133. ! 50: error messages
  134. !
  135. @LABEL 50
  136. exit -6021
  137. !
  138. @LABEL 52
  139. exit -6020
  140. !
  141. @LABEL 53
  142. exit -6022
  143. !
  144. @LABEL 54
  145. exit -6023
  146. !
  147. @LABEL 59
  148. exit -6019
  149. !
  150. @LABEL 70
  151. setspeed 19200
  152. jump 71
  153. !
  154. ! Hang up the modem
  155. !
  156. @HANGUP
  157. @LABEL 60
  158. settries 0
  159. HSReset 0 0 0 0 0 0 
  160. @LABEL 61
  161. write "ATH\13"
  162. matchclr
  163. matchstr 1 62 "NO CARRIER\13\10"
  164. matchstr 2 62 "OK\13\10"
  165. matchstr 3 62 "ERROR\13\10"
  166. matchread 30
  167. inctries
  168. iftries 3 59
  169. iftries 2 70
  170. !
  171. @LABEL 71
  172. ! no response, try escape sequence
  173. pause 12
  174. write "+++"
  175. matchclr
  176. matchstr 1 61 "OK\13\10"
  177. matchread 18
  178. ! try dropping DTR
  179. DTRClear
  180. pause 15
  181. DTRSet
  182. pause 15
  183. jump 61
  184. !
  185. @LABEL 62
  186. ! recall the factory settings
  187. pause 15
  188. write "AT&F\13"
  189. matchclr
  190. matchstr 1 63 "OK\13\10"
  191. matchread 30
  192. !
  193. @LABEL 63
  194. pause 5
  195. matchstr 1 64 "OK\13\10"
  196. write "ATS0=0\13"
  197. matchread 20
  198. !
  199. @LABEL 64
  200. exit 0
  201.  
  202.